#include <iostream>
#include <iomanip>
#include <fstream>
#include <cstdlib>
#include <ctime>
#include <memory>
#include <algorithm>
#include <numeric>
#include <vector>
#include <iterator>
#include <functional>
#include <boost/bind.hpp>
#include <boost/timer.hpp>
#include <boost/shared_ptr.hpp>

using namespace std;

struct Dog
{
	static void* operator new (size_t size)
	{
		void *p = ::operator new(size);
		cout<<"Create a new Dog."<<endl;
		return p;
	}

	static void operator delete(void *p)
	{
		::operator delete(p);
		cout<<"Delete a Dog."<<endl;
	}
};

int main(int argc, char **argv)
{
	//for(;;)
	//	auto_ptr<Dog>(new Dog);
	for(;;)
		boost::shared_ptr<Dog>(new Dog);

	return 0;
}
